home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 2 / Apprentice-Release2.iso / Tools / Languages / MacHaskell 2.2 / type / default.scm next >
Encoding:
Text File  |  1994-09-27  |  1.6 KB  |  14 lines  |  [TEXT/CCL2]

  1. ;;; This handles the default rule.
  2.  
  3. (define (maybe-default-ambiguous-tyvar type def module)
  4.   (let ((classes (ntyvar-context type)))
  5.    (and (not (null? classes)) ; this happens only during cleanup after an error
  6.     (let ((non-standard? '#f)
  7.       (numeric? '#f))
  8.       (dolist (class classes)
  9.     (cond ((eq? (class-kind class) 'numeric)
  10.            (setf numeric? '#t))
  11.           ((not (eq? (class-kind class) 'standard))
  12.            (setf non-standard? '#t))))
  13.       (cond ((or non-standard? (not numeric?))
  14.          (remember-c